clear

use "C:\Users\smamo\OneDrive - konkuk.ac.kr\research\my papers\new papers\cyclicality\new\analysis\reduced_iso_dpi_ethnic.dta"


gen president=0
replace president=1 if system<=1

gen proportional=0
replace proportional=1 if housesys==0


gen loggdppc_ppp=log(gdppc_ppp2010)

reg cyclicality president proportional  ethnic loggdppc_ppp if housesys!=-999, robust
reg cyclicality  president proportional  ethnic loggdppc_ppp if housesys!=-999 & gdppc_ppp2010>=10000, robust
reg cyclicality  president proportional  ethnic loggdppc_ppp if housesys!=-999 & gdppc_ppp2010<10000, robust

reg cyclicality  president proportional  ethnic loggdppc_ppp if housesys!=-999 & advanced==1, robust
reg cyclicality  president proportional  ethnic loggdppc_ppp if housesys!=-999 & sahara==1, robust

graph twoway (scatter cyclicality loggdppc_ppp, msize(vsmall)) (lfit cyclicality loggdppc_ppp)  if cyclicality>-2 
graph twoway (scatter cyclicality loggdppc_ppp, msize(vsmall) mlabel(ifs)) (lfit cyclicality loggdppc_ppp)  if cyclicality>-2 & advanced==1
graph twoway (scatter cyclicality loggdppc_ppp, msize(vsmall) mlabel(ifs)) (lfit cyclicality loggdppc_ppp)  if cyclicality>-2 & sahara==1

